<template>
	<view class="page">
		<template v-if="isLogin"> 
			<view class="start-btn-area"> 				
				<!-- 监测作业 -->
				<navigator :url="'/package_project/jc_pro/jcForm/jcForm?pro_name='+params.pro_name+'&pid='+params.pid" hover-class="none" class="btn">
					<image :src="web_host+'/wxicon/pc_start.png'" mode="widthFix"></image>
				</navigator>
				<view class="name"><text>{{params.pro_name}}</text></view>				
			</view>			 
		</template>
	</view>
</template>

<script>
	import { 
		WEB_HOST
	} from '@/config.js'
	
	export default {
		name: 'name',
		data() {
			return { 
				isLogin: false, 
				userInfo: uni.getStorageSync('userInfo'),
				loginStateUpdate: false,
				app_name: getApp().globalData.app_name,
				params:{
					pid:'',
					pro_type:'',
					pro_name:''
				},
				web_host:getApp().globalData.web_host

			}


		},
		async onLoad(params) {	 
			this.isLogin=await this.$loginState('check');  
			this.params.pro_type=params.pro_type;
			this.params.pro_name=params.pro_name;
			this.params.pid=params.pid;
			if(params.type){
				this.params.type=params.type;
			}
			
			if(params.pro_type==3||params.pro_type==2){
				uni.setNavigationBarTitle({
					title:"监测作业"
				})
			} 
			if(params.pro_type==1){
				if(params.type=='fx'){
					uni.setNavigationBarTitle({
						title:"防效检查"
					})
				}else{
					uni.setNavigationBarTitle({
						title:"防控作业"
					})
				}
				
			}
			
			
		},
		async onShow() {

		},
		methods: {
			
		},
		components: {

		},

		computed: {

		},
		watch: {

		}

	}
</script>

<style lang="less" scoped> 
	.category-list{
		background: #fff;
		margin-bottom: 20rpx;
		padding: 30rpx 0 0;
		.item{
			.icon{
				width: 40%!important;
			}
		}
	}
	.name {
		text-align: center;

		text {
			padding-top: 10rpx;
			border-top: 2rpx dashed #999;
			font-size: 28rpx;
			color: #999;
		}
	}
	.start-btn-area{
		position:absolute;
		left:0;
		bottom:250rpx;
		width:100%;
	}
	
	.btn {
		width: 60%;
		margin: 0 auto;
	
		image {
			width: 100%;
		}
	}

	// .btn {
	// 	border-radius: 50%;
	// 	width: 280rpx;
	// 	height: 280rpx;
	// 	line-height: 280rpx;
	// 	margin: 250rpx auto 0;
	// 	background-image: linear-gradient(to right, #fe5d55, #e2231a);
	// 	box-shadow: 0 0 10rpx #000;
	// 	font-size: 40rpx;
	// 	text-align: center;
	// 	color:#fff;
	// }
	
	
</style>
